<?php


namespace app\common\model;


class Room extends BaseModel{

    protected $updateTime = false;

    public function roomChat(){
        return $this->hasMany('RoomChat','room_id','id')->order('created_at','desc')->limit(1);
    }

    public function levelInfo(){
        return $this->belongsTo('RoomLevel','level','id');
    }

    public static function updatePeople($roomId){

    }
}